<template>
  <el-tooltip class="item" effect="dark" :content="data" placement="top-start">
    <template #content>
      <p style="max-width: 260px"
        :style="{ color: colInfo.getColor && typeof colInfo.getColor == 'function' ? colInfo.getColor(data) : '' }">
        {{ data }}
      </p>
    </template>
    <span class="ellipsis-span"
      :style="{ color: colInfo.getColor && typeof colInfo.getColor == 'function' ? colInfo.getColor(data) : '' }">{{
    data
      }}</span>
  </el-tooltip>
</template>
<script>
import { color } from 'echarts';

export default {
  name: "tableTooltip",
  components: {},
  props: {
    data: {
      type: String,
      default: () => '',
    },
    colInfo: {
      type: Object,
      default: () => { return {} }
    }
  },
  data() {
    return {};
  },
  methods: {},
  created() { },
  mounted() { },
};
</script>
<style lang="scss" scoped></style>
